package com.zerocode.smarttravel.ui

import android.os.Bundle
import androidx.fragment.app.Fragment
import com.zerocode.smarttravel.R
import com.zerocode.smarttravel.base.BaseFragment
import com.zerocode.smarttravel.databinding.FragmentHomeLayoutBinding
import com.zerocode.smarttravel.tools.StatusBarUtil

/**
 * 首页
 * @author YSJ
 * @date 2021/7/13 : 20:23
 */
class HomeFragment : BaseFragment<FragmentHomeLayoutBinding>() {

    override fun getLayout(savedInstanceState: Bundle?): Int = R.layout.fragment_home_layout



    override fun initEvent() {
        val statusBarHeight = StatusBarUtil.getStatusBarHeight(context)
        // 动态在代码里面去设置view的宽高
        val lp = binding?.stateBar?.layoutParams
        lp?.height=statusBarHeight
        binding?.stateBar?.layoutParams=lp
    }

    override fun initData() {

    }
}